package com.googlecode.springgameengine.rendering;

import com.googlecode.springgameengine.actor.Actor;
import java.util.HashMap;
import java.util.Map;

//TODO: ta implementacja jest bezsensu, bo nie pozwala na dziedziczenie po aktorach!!!

/**
 *
 * @author Maciej
 */
public class ActorRendererMap extends ActorRendererResolver {
	
	private Map<Class<? extends Actor>, ActorRenderer> actorRendererMap = new HashMap<>();

	@Override
	public <T extends Actor> ActorRenderer<T> resolve(T actor) {
		return actorRendererMap.get(actor.getClass());
	}

	public Map<Class<? extends Actor>, ActorRenderer> getActorRendererMap() {
		return actorRendererMap;
	}

	public void setActorRendererMap(Map<Class<? extends Actor>, ActorRenderer> actorRendererMap) {
		this.actorRendererMap = actorRendererMap;
	}
	
}
